<template>
  <div class="content-category">
    <grid-view :cols="3" :lineSpace="15" :v-margin="20"
               v-if="subCategories">
      <div class="category-item" v-for="(item,index) in subCategories" :key="index">
        <div><a :href="item.link"><img :src="item.image" alt=""></a></div>
        <div>{{item.title}}</div>
      </div>
    </grid-view>
  </div>
</template>

<script>
import GridView from "@/components/common/gridview/GridView";

export default {
  name: "TabContentCategory",
  components:{
    GridView
  },
  props: {
    subCategories:{
      type:Array,
      default() {
        return []
      }
    }
  },

}
</script>

<style scoped>
.category-item div{
  text-align: center;
  font-size: 14px;
}
.category-item div:first-child img{
  width: 80%;
}
.category-item div:last-child{
  margin-top: 5px;
}
</style>
